home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1998 April: Mac OS SDK / Dev.CD Apr 98 SDK1.toast / Development Kits (Disc 1) / Interfaces&Libraries / Universal / Interfaces / PInterfaces / DiskInit.p < prev    next >
Encoding:
Text File  |  1998-02-12  |  4.1 KB  |  133 lines  |  [TEXT/MPS ]

  1. {
  2.      File:        DiskInit.p
  3.  
  4.      Contains:    Disk Initialization Package ('PACK' 2) Interfaces.
  5.  
  6.      Version:    Technology:    System 8.1
  7.                  Release:    Universal Interfaces 3.1
  8.  
  9.      Copyright:    © 1985-1995, 1997-1998 by Apple Computer, Inc., all rights reserved
  10.  
  11.      Bugs?:        Please include the the file and version information (from above) with
  12.                  the problem description.  Developers belonging to one of the Apple
  13.                  developer programs can submit bug reports to:
  14.  
  15.                      devsupport@apple.com
  16.  
  17. }
  18. {$IFC UNDEFINED UsingIncludes}
  19. {$SETC UsingIncludes := 0}
  20. {$ENDC}
  21.  
  22. {$IFC NOT UsingIncludes}
  23.  UNIT DiskInit;
  24.  INTERFACE
  25. {$ENDC}
  26.  
  27. {$IFC UNDEFINED __DISKINIT__}
  28. {$SETC __DISKINIT__ := 1}
  29.  
  30. {$I+}
  31. {$SETC DiskInitIncludes := UsingIncludes}
  32. {$SETC UsingIncludes := 1}
  33.  
  34. {$IFC UNDEFINED __MACTYPES__}
  35. {$I MacTypes.p}
  36. {$ENDC}
  37.  
  38.  
  39. {$PUSH}
  40. {$ALIGN MAC68K}
  41. {$LibExport+}
  42.  
  43.  
  44. TYPE
  45.     HFSDefaultsPtr = ^HFSDefaults;
  46.     HFSDefaults = RECORD
  47.         sigWord:                PACKED ARRAY [0..1] OF CHAR;            {  signature word  }
  48.         abSize:                    LONGINT;                                {  allocation block size in bytes  }
  49.         clpSize:                LONGINT;                                {  clump size in bytes  }
  50.         nxFreeFN:                LONGINT;                                {  next free file number  }
  51.         btClpSize:                LONGINT;                                {  B-Tree clump size in bytes  }
  52.         rsrv1:                    INTEGER;                                {  reserved  }
  53.         rsrv2:                    INTEGER;                                {  reserved  }
  54.         rsrv3:                    INTEGER;                                {  reserved  }
  55.     END;
  56.  
  57.  
  58. CONST
  59.     kHFSPlusDefaultsVersion        = 1;
  60.  
  61.  
  62. TYPE
  63.     HFSPlusDefaultsPtr = ^HFSPlusDefaults;
  64.     HFSPlusDefaults = RECORD
  65.         version:                UInt16;                                    {  version of this structure  }
  66.         flags:                    UInt16;                                    {  currently undefined; pass zero  }
  67.         blockSize:                UInt32;                                    {  allocation block size in bytes  }
  68.         rsrcClumpSize:            UInt32;                                    {  clump size for resource forks  }
  69.         dataClumpSize:            UInt32;                                    {  clump size for data forks  }
  70.         nextFreeFileID:            UInt32;                                    {  next free file number  }
  71.         catalogClumpSize:        UInt32;                                    {  clump size for catalog B-tree  }
  72.         catalogNodeSize:        UInt32;                                    {  node size for catalog B-tree  }
  73.         extentsClumpSize:        UInt32;                                    {  clump size for extents B-tree  }
  74.         extentsNodeSize:        UInt32;                                    {  node size for extents B-tree  }
  75.         attributesClumpSize:    UInt32;                                    {  clump size for attributes B-tree  }
  76.         attributesNodeSize:        UInt32;                                    {  node size for attributes B-tree  }
  77.         allocationClumpSize:    UInt32;                                    {  clump size for allocation bitmap file  }
  78.     END;
  79.  
  80.  
  81. PROCEDURE DILoad;
  82.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  83.     INLINE $7002, $3F00, $A9E9;
  84.     {$ENDC}
  85. PROCEDURE DIUnload;
  86.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  87.     INLINE $7004, $3F00, $A9E9;
  88.     {$ENDC}
  89. FUNCTION DIBadMount(where: Point; evtMessage: LONGINT): INTEGER;
  90.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  91.     INLINE $7000, $3F00, $A9E9;
  92.     {$ENDC}
  93. FUNCTION DIFormat(drvNum: INTEGER): OSErr;
  94.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  95.     INLINE $7006, $3F00, $A9E9;
  96.     {$ENDC}
  97. FUNCTION DIVerify(drvNum: INTEGER): OSErr;
  98.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  99.     INLINE $7008, $3F00, $A9E9;
  100.     {$ENDC}
  101. FUNCTION DIZero(drvNum: INTEGER; volName: Str255): OSErr;
  102.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  103.     INLINE $700A, $3F00, $A9E9;
  104.     {$ENDC}
  105. {
  106.     DIXFormat, DIXZero, and DIReformat are only available when FSM (File System Manager) is installed.
  107.     FSM is part of Macintosh PC Exchange and System 7.5.
  108. }
  109. FUNCTION DIXFormat(drvNum: INTEGER; fmtFlag: BOOLEAN; fmtArg: UInt32; VAR actSize: UInt32): OSErr;
  110.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  111.     INLINE $700C, $3F00, $A9E9;
  112.     {$ENDC}
  113. FUNCTION DIXZero(drvNum: INTEGER; volName: Str255; fsid: INTEGER; mediaStatus: INTEGER; volTypeSelector: INTEGER; volSize: UInt32; extendedInfoPtr: UNIV Ptr): OSErr;
  114.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  115.     INLINE $700E, $3F00, $A9E9;
  116.     {$ENDC}
  117. FUNCTION DIReformat(drvNum: INTEGER; fsid: INTEGER; volName: Str255; msgText: Str255): OSErr;
  118.     {$IFC TARGET_OS_MAC AND TARGET_CPU_68K AND NOT TARGET_RT_MAC_CFM}
  119.     INLINE $7010, $3F00, $A9E9;
  120.     {$ENDC}
  121.  
  122.  
  123. {$ALIGN RESET}
  124. {$POP}
  125.  
  126. {$SETC UsingIncludes := DiskInitIncludes}
  127.  
  128. {$ENDC} {__DISKINIT__}
  129.  
  130. {$IFC NOT UsingIncludes}
  131.  END.
  132. {$ENDC}
  133.